<?php
require_once REPOMATH_ROOT . '/util/DBUtil.class.php';

class Material {
	var $db;

	public function Material() {
		$this->db = new DBUtil();
	}

	public function getMaterialByTo_id($to_id) {
		$rows = $this->db->ExQueryGetArray("select a.* from tbl_material a, tbl_ma_to b " .
		"where a.Ma_id = b.Ma_To_material_id and b.Ma_To_topic_id = $to_id");
		return $rows;
	}
}
?>